home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 76 / XENIATGM66.iso / Indiana Jones / Indiana Jones.exe / RESOURCE / PREVIEW.GOB / cog_gen_doorrotate2.cog < prev    next >
Text File  |  1999-11-15  |  1KB  |  53 lines

  1. # Jones 3D Cog Script
  2. #
  3. # gen_DoorRotate2.cog
  4. #
  5. # "Simplified" rotating Door Script.
  6. #
  7. # [TRM]
  8. #
  9. # (C) 1998 LucasArts Entertainment Co. All Rights Reserved
  10. # ========================================================================================
  11.  
  12. symbols        
  13.     
  14.     message     startup
  15.     message     activate    
  16.  
  17.     thing        door0
  18.     thing        player        local
  19.  
  20.     int         doorsopen=0          local
  21.  
  22.     flex        openspeed=2.0
  23.  
  24. end
  25.  
  26. # ========================================================================================
  27.  
  28. code
  29.  
  30. startup:
  31.  
  32.     player = GetLocalPlayerThing();
  33.     return;
  34.  
  35. # ========================================================================================
  36.  
  37. activate:
  38.  
  39.     if (GetSenderRef() == door0)
  40.         {
  41.             if (doorsopen == 1) return;
  42.             doorsopen = 1;
  43.             PlayMode(player, 60, 1);
  44.             Rotate(door0, -90, 1, openspeed);
  45.         }
  46.  
  47.     return;
  48.  
  49. # ========================================================================================
  50.  
  51. end
  52.  
  53.